home *** CD-ROM | disk | FTP | other *** search
/ Libris Britannia 4 / science library(b).zip / science library(b) / PROGRAMM / PASCAL / 0798.ZIP / SE.DOC < prev    next >
Text File  |  1987-10-05  |  90KB  |  2,783 lines

  1.  
  2.  
  3.  
  4.  
  5.  
  6.  
  7.  
  8.  
  9.  
  10.  
  11.  
  12.  
  13.  
  14.  
  15.  
  16.  
  17.                                  ScreenEngine
  18.  
  19.  
  20.  
  21.  
  22.                 A screen design program for Turbo Pascal users
  23.  
  24.  
  25.  
  26.  
  27.  
  28.  
  29.                                       by
  30.  
  31.  
  32.                         Pedro J. and Jennifer L. Restrepo
  33.  
  34.  
  35.  
  36.  
  37.                              Newton Microsoftware
  38.  
  39.                                  P.O. Box 318
  40.                                 New Town Branch
  41.                              Boston, MA     02258
  42.  
  43.  
  44.  
  45.  
  46.           Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  47.  
  48.  
  49.  
  50.  
  51.  
  52.  
  53.  
  54.  
  55.  
  56.  
  57.  
  58.        Introduction to ScreenEngine..........................................1
  59.             Ordering ScreenEngine............................................1
  60.             Introduction to ScreenEngine.....................................2
  61.                 Basic Concepts...............................................2
  62.                 A Short Glossary.............................................2
  63.                 ScreenEngine Menus...........................................3
  64.                      Menus for Color or Monochrome Monitors..................3
  65.                      Main Menu Options.......................................3
  66.                 The File Directory Utility...................................4
  67.                 Moving the Cursor Around the Screen..........................4
  68.                 Marking or Pointing at Items.................................5
  69.                 Making Complex Boxes.........................................5
  70.                 Sorting Items................................................5
  71.                      Boxes...................................................5
  72.                      Variables...............................................6
  73.                 The Program's Output.........................................6
  74.                 The Sample Files.............................................8
  75.       ScreenEngine Reference.................................................9
  76.            The Main Menu.....................................................9
  77.                 Make.........................................................9
  78.                 Retrieve....................................................10
  79.                 Save........................................................10
  80.                 Clear.......................................................11
  81.                 Quit........................................................11
  82.            Screen Design Menu...............................................12
  83.                 Box.........................................................12
  84.                      Complex Box............................................13
  85.                 Label.......................................................14
  86.                 Variable....................................................15
  87.                 Change Box..................................................16
  88.                      Background.............................................16
  89.                      Foreground.............................................17
  90.                      Type...................................................17
  91.                      Size...................................................17
  92.                      Execute................................................18
  93.                 Change Label................................................18
  94.                      Background.............................................18
  95.                      Foreground.............................................19
  96.                      Label..................................................19
  97.                      Execute................................................19
  98.                 Change Variable.............................................19
  99.                      Background.............................................20
  100.                      Foreground.............................................20
  101.                      Name...................................................20
  102.                      Type...................................................21
  103.                      Type Integer...........................................21
  104.                      Type Real..............................................22
  105.                      Type String............................................22
  106.                      Type Date..............................................22
  107.                      Length.................................................24
  108.  
  109.  
  110.  
  111.  
  112.  
  113.  
  114.  
  115.  
  116.                      Display................................................24
  117.                      Display Scientific.....................................24
  118.                      Display Fixed..........................................25
  119.                      Display Dollar.........................................25
  120.                      Display Percent........................................26
  121.                      Display Comma..........................................26
  122.                      Protection.............................................26
  123.                      MinMax.................................................27
  124.                      Execute................................................28
  125.                 Move........................................................29
  126.                      Item...................................................29
  127.                      Range..................................................29
  128.                 Duplicate...................................................31
  129.                 Alter.......................................................32
  130.                 Erase.......................................................33
  131.                 UnErase.....................................................34
  132.                 Sort........................................................35
  133.                      Variables..............................................35
  134.                      Boxes..................................................35
  135.                 Quit........................................................36
  136.       The Generated Program and the ScreenEngine utilites...................37
  137.            The Generated Program............................................37
  138.                 Generated Procedures........................................37
  139.                      ScrnXXXX...............................................37
  140.                      PutTitleScrnXXXX.......................................37
  141.                      OutVarScrnXXXX.........................................37
  142.                      InpVarScrnXXXX.........................................37
  143.                      InpScrXXXX.............................................38
  144.                      EditScrXXXX............................................38
  145.                      OutScrXXXX.............................................38
  146.                 Predefined Variables........................................39
  147.            The ScreenEngine Utilities.......................................40
  148.                 SE.UTL......................................................40
  149.                      Beep...................................................40
  150.                      Box....................................................40
  151.                      GetString..............................................40
  152.                      GetVariable............................................41
  153.                      MakeStr................................................41
  154.                      NormCursor.............................................41
  155.                      PeelBlanks.............................................41
  156.                      PutVariable............................................41
  157.                      SCursor................................................41
  158.                      SetColor...............................................42
  159.                      Reset Color............................................42
  160.                 SEREAL.UTL..................................................42
  161.                      ConvReal...............................................42
  162.                      GetReal................................................42
  163.                      InsCommas..............................................42
  164.                      PeelChars..............................................43
  165.                      PutReal................................................43
  166.  
  167.  
  168.  
  169.  
  170.  
  171.  
  172.  
  173.  
  174.                 SEINT.UTL...................................................43
  175.                      GetInteger.............................................43
  176.                      PutInteger.............................................43
  177.                 SEDATE.UTL..................................................43
  178.                      GetDate................................................43
  179.                      MakeDateStr............................................43
  180.                      PutDate................................................43
  181.  
  182.  
  183.  
  184.  
  185.  
  186.  
  187. Introduction                                                         Page    1
  188.  
  189.  
  190.  
  191.                          INTRODUCTION TO ScreenEngine
  192.  
  193. ScreenEngine is a  tool that  will assist you  in designing  screens for input
  194. and output  of  variables  in  your Turbo  Pascal  programs.   ScreenEngine is
  195. distributed under the "ShareWare" concept,  that means that you are allowed to
  196. make  and  distribute  copies  of  the  program,   provided  that  you  do not
  197. modify the program in any way, nor receive monetary compensation. If you   use
  198. the program, you  are asked to send $30.00 (Mass.  residents send $31.50)  for
  199. each working copy of the  program, in U.S.  currency   (Check or money order).
  200. Site  licenses are available.  Registered  users will be kept  informed of new
  201. releases.
  202. -----------------------------------------------------------------------------
  203.                TO: Newton Microsoftware
  204.                Post Office Box # 318
  205.                New Town Branch
  206.                Boston, MA 02258
  207.  
  208.  
  209.  
  210.  
  211.                Please send me ____ copies of ScreenEngine at $30.00 each.
  212.  
  213.                (Mass. residents add $1.50 per copy)
  214.  
  215.                Name______________________________________
  216.  
  217.  
  218.                Address__________________________________
  219.  
  220.  
  221.                City or Town______________  State__  ZIP______
  222.  
  223.  
  224. -----------------------------------------------------------------------------
  225.  
  226. All  the rights to  this program are  reserved by Pedro  J.  Restrepo,  Newton
  227. Microsoftware.  Please address in writing all questions regarding ScreenEngine
  228. to the above address.
  229.  
  230. This program is provided as is and no warrantee,  expressed or implied,is made
  231. as  to its usefulness for any intended purpose or its reliability.  The author
  232. is not liable for any loss resulting from the use of this program.
  233.  
  234.  
  235.  
  236.  
  237.  
  238.  
  239.  
  240.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  241.  
  242.  
  243.  
  244.  
  245.  
  246.  
  247. Introduction                                                         Page    2
  248.  
  249.  
  250. Introduction to ScreenEngine.
  251.  
  252. Basic Concepts.
  253.  
  254. Use  a computer with an IBM color graphics card,  an Enhanced Graphics adapter
  255. or compatible to fully appreciate the program's capabilities. (The program has
  256. been tested on IBM,  Compaq and Zenith machines).  ScreenEngine will also work
  257. well  on machines  with monochrome  or Hercules  card and  monitor,  but since
  258. monochrome  monitors like the  IBM do not  display shades of  green instead of
  259. colors,   users may not be able to  completely see a screen which was designed
  260. for  color monitors.  Color  monitors include the  true multi-hued monitors as
  261. well  as those offering  several shades of one color  (amber,  green or gray),
  262. like  those in the Compaq and the  AT&T computers.  The "color" options of the
  263. monochrome monitors are:
  264.  
  265.   (1) Dark screen background and bright text.
  266.   (2) Dark screen background and underlined text.
  267.   (3) Bright screen background and dark text.
  268.  
  269. ScreenEngine  will automatically  detect which graphics  adapter is active and
  270. set the internal color options accordingly. To execute the program, change the
  271. active  directory to the  directory in which  the program was  copied and type
  272. either  "SE".  ScreenEngine will initialize the system and read two files that
  273. must  reside in the same directory as SE.COM.  These three files are:  SE.000,
  274. SE.MSG  and  SE.MNU.   SE.000 contains  some  programs which  are  required to
  275. initialize the system. SE.MNU and SE.MSG contain the menus and error messages,
  276. respectively.  If the program can't find the ".MNU" AND ".MSG" files,  it will
  277. ask you to input the name of the directory in which they are stored.
  278.  
  279.  
  280. A Short Glossary:
  281.  
  282. In  this manual and  in ScreenEngine each  entry on the  screen constitutes an
  283. "item".  There are 3 types of items:  Boxes, Labels and Variables. A "box" may
  284. be  either a rectangular or  square box,  a line  or an individual box-drawing
  285. character.   A "label" is  anything you write on  the screen,  like  titles or
  286. headings.   A "variable" is actually the area  on the screen where you want to
  287. input or output a variable.
  288.  
  289.  
  290.  
  291.  
  292.  
  293.  
  294.  
  295.  
  296.  
  297.  
  298.  
  299.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  300.  
  301.  
  302.  
  303.  
  304.  
  305.  
  306. Introduction                                                         Page    3
  307.  
  308.  
  309. ScreenEngine Menus.
  310.  
  311. All ScreenEngine menus include 2 lines:
  312.  
  313. The first line displays the menu choices. One of the choices is highlighted in
  314. reverse video. The highlighting may be moved among menu selections by pressing
  315. the [Right] and [Left] arrow keys. You may choose the highlighted selection by
  316. pressing [ENTER]. You may also choose any option by typing the first letter of
  317. the menu selection without the need to highlight the choice.
  318.  
  319. The  second  line  of  each  menu  describes  the  function  of  the currently
  320. highlighted selection.  Many of these description lines are fully explanatory.
  321. In the reference manual we will describe all menus and their submenus, and the
  322. queries  from the program  that the user  is required to  answer for some menu
  323. selections.
  324.  
  325. In  all descriptive sections  of the reference manual,   we will highlight the
  326. current  choice  by  using  upper  case letters.   The  menu  prompt  and menu
  327. selections  will appear with the description  line for the current menu choice
  328. right below. The general form will look like the following:
  329.  
  330. =========================================================================
  331. MENU PROMPT LINE (If any)
  332. First-choice   Second-choice   CURRENT-CHOICE  Fourth-choice
  333. Description line for current choice
  334. =========================================================================
  335.  
  336. A description of CURRENT-CHOICE will then follow.
  337.  
  338.  
  339. Menus for Color or Monochrome Monitors.
  340.  
  341. Because  of  the imposibility  of  the monochrome  display  to show  any "Gray
  342. Scale"  colors  except reverse  video,  ScreenEngine  has two  different color
  343. menus: the "color" menu for the monochrome adaptor gives the choices of normal
  344. video,   reverse video or  underlined.  The color menu  for the color graphics
  345. adapter  has 8 different choices for  background and 16 choices for foreground
  346. colors.   ScreenEngine  will  not  allow the  same  colors  for foreground and
  347. background, because this will make the foreground invisible.
  348.  
  349.  
  350. Main Menu options:
  351.  
  352. The  first option,   "Make",  allows  you to either  create a  new screen,  or
  353. continue  editing.  The second option,  "Retrieve",  allows you to specify the
  354. name of a screen you previously created (and "Saved"). Use this option to read
  355. the file SAMPLE.PAS into SE.  When prompted for the file name, you do not have
  356. to  type the .PAS extension.  After you have retrieved the existing SAMPLE.PAS
  357.  
  358.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  359.  
  360.  
  361.  
  362.  
  363.  
  364.  
  365. Introduction                                                         Page    4
  366.  
  367.  
  368. file,   you will be in the "SCREEN DESIGN MENU".  The menu area is permanently
  369. displayed.
  370.  
  371. The File Directory Utility.
  372.  
  373. ScreenEngine is equipped with a versatile file directory.  It is automatically
  374. displayed  in two cases:  1)  when you type  a "?" instead of a file name when
  375. responding  to the "Retrieve" option  of the main menu;   and 2)  when you are
  376. saving  your file and  ScreenEngine finds that  there is no  more space on the
  377. disk.  The file directory utility displays up to 255 files per directory.  The
  378. file  names or directories are sorted alphabetically by name.  Directories are
  379. marked with a "D*" at their right.
  380.  
  381.  
  382. Using the Directory Utility.
  383.  
  384.       Selecting a file.
  385.  
  386.       To  assist you with  the selection of the  file,  your default directory
  387.       will be displayed. Use the cursor keys to highlight the file you want to
  388.       RETRIEVE.   By pressing [ENTER],  ScreenEngine will read the highlighted
  389.       file.
  390.  
  391.  
  392.       Changing directories.
  393.  
  394.       There  are two  ways of  changing directories  within ScreenEngine.  The
  395.       first  one is by highlighting a  subdirectory and pressing [ENTER].  The
  396.       second one is by typing "C" and then typing the complete Path,  starting
  397.       with the drive designator.  In both cases, ScreenEngine will display the
  398.       files and directories in that subdirectory.  Use the second technique to
  399.       list  another  drive's directory.   To return  to the  parent directory,
  400.       highlight the ".." directory and press [ENTER].
  401.  
  402.  
  403.       Erasing a file.
  404.  
  405.       ScreenEngine  lets you erase a file in case you are running out of space
  406.       on your disk. To do so, type "E" and the file will be erased.
  407.  
  408.  
  409.  
  410. Moving the Cursor Around the Screen:
  411.  
  412. Use  the arrow keys in the normal way.  The [Home],  [PgUp],  [PgDn] and [End]
  413. keys  will move the cursor diagonally.  By pressing the [Ctrl] key at the same
  414. time   as  any  of  the  keys  that  move  the  cursor  either  diagonally  or
  415. horizontally,  the cursor horizontal movement is accelerated by a factor of 5.
  416.  
  417.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  418.  
  419.  
  420.  
  421.  
  422.  
  423.  
  424. Introduction                                                         Page    5
  425.  
  426.  
  427. You  may  move the  cursor  anywhere on  the  screen.  You may  position items
  428. anywhere on the screen,  exept at the bottom right corner (Row 25,  Col 80) of
  429. the  screen,  since this would cause the screen  to scroll up.  If you want to
  430. position  an item in the area normally used by the ScreenEngine menu just move
  431. the  cursor to the desired location.  ScreenEngine will automatically move the
  432. menu display area to the top of the screen, until you place the cursor in that
  433. area.
  434.  
  435.  
  436. Marking or Pointing at Items:
  437.  
  438. Some  menu options will ask you  to point at an item  to mark it.  To do this,
  439. place the  cursor anywhere  on the label,   the variable location,   or on the
  440. border of a box  a line, or a graphic character and press [Enter].
  441.  
  442.  
  443. Making Complex Boxes:
  444.  
  445. This is probably one of the most useful options of ScreenEngine.  We mean by a
  446. "Complex  box" a box that has internal divisions,  special graphics characters
  447. or  other boxes.  ScreenEngine treats a complex  box as a unity when changing,
  448. duplicating, erasing or moving the box. However, when "Unerasing" a previously
  449. erased  complex box,  only the "Mother box"  will be recreated.  You may move,
  450. erase,   unerase,   duplicate,   but  not  change the  colors  of  any  of the
  451. subcomponents of the complex box. You may make any other mother boxes with any
  452. other colors,  inside, outside, or overlapping any existing box. The advantage
  453. of this approach lies in the very compact source code that is produced. Notice
  454. the  first call to the "Box" procedure  in the source SAMPLE.PAS program.  The
  455. string  within quotes contains the  information regarding the subcomponents of
  456. the mother box.
  457.  
  458.  
  459. Sorting Items:
  460.  
  461. There are two reasons for which you may want to "Sort" items.
  462.  
  463. Sorting Boxes:
  464.  
  465.     If you decided to include a box covering an area in which you already have
  466.     laid out some boxes, you will find that the background of the new box will
  467.     cover the existing boxes underneath. Choose the "Sort" command, select the
  468.     "Box" option,  and ScreenEngine will display the screen in a "See-through"
  469.     mode  that will allow you to see all boxes.  "Mark" the boxes in the order
  470.     in  which you want them  to be displayed in the  screen.  You only have to
  471.     mark  the "Mother" boxes.  ScreenEngine will type the order of the box you
  472.     have  just marked on the  upper left corner of  the box,  both to indicate
  473.  
  474.  
  475.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  476.  
  477.  
  478.  
  479.  
  480.  
  481.  
  482. Introduction                                                         Page    6
  483.  
  484.  
  485.     that  the box has already been marked,   and to remaind you of the sorting
  486.     order.  Press [Enter] twice when marking the last box to indicate that you
  487.     have finished.
  488.  
  489. Sorting Variables:
  490.  
  491.     ScreenEngine will normally generate the source program in a form that will
  492.     prompt  the user  to input the  variables in  the same order  in which the
  493.     variables  were created when the screen was originally designed.  However,
  494.     the designer of the screen may have moved variables around, or may want to
  495.     specify  a particular order  in which the variables  should be input.  The
  496.     "Sort  Variables" option will enable the designer to indicate the order in
  497.     which  the variables should be  prompted to the user.   As in the "Sorting
  498.     Boxes"  case,  "Mark" the variables in the order in which you want them to
  499.     be prompted.
  500.  
  501. The Program's Output.
  502.  
  503. As  already  mentioned, SE  will  write a  source  Turbo  Pascal  program that
  504. you  can  modify and  enhance to  suit your  needs.  At  the beginning  of the
  505. program, SE includes a Turbo Pascal comment that has screen coordinates, color
  506. and  other information useful  in reconstructing the  screen.  The contents of
  507. this comment is described next:
  508.  
  509. The first line always is:
  510.  
  511. (*SCREENENGINE
  512.  
  513. The second line contains the name you gave to the screen. For instance:
  514.  
  515. Test
  516.  
  517. The third line always contains 4 integer values:
  518.  
  519. MonType BgCol FgCol NItems
  520.  
  521. Montype is the type of monitor you are using: 1=color, 2= monochrome.
  522. BgColor is the color of the screen Background.
  523. FgColor is the color of the screen Foreground.
  524. NItems is the number of items you created. The following count as one item:
  525.      A single box.
  526.      A single line.
  527.      A single box-drawing character.
  528.      A label (Up to 80 characters long).
  529.      A variable.
  530.  
  531. Next, the program will write "NItems" lines with the following data:
  532.  
  533.  
  534.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  535.  
  536.  
  537.  
  538.  
  539.  
  540.  
  541. Introduction                                                         Page    7
  542.  
  543.  
  544. xo yo x1 y1 L BgCol FgCol Code Protec/Ref NameS;
  545.  
  546. xo,yo : Upper left corner coordinates.
  547.  
  548. x1,y1 : For boxes, lower right corner coordinates.
  549.         Unused for labels, integer variables and string variables.
  550.         For  real  variables x1  indicates  the format  and  y1 the  number of
  551.         decimals.
  552.         For Date variables x1 indicates the format.
  553.  
  554. L     : For rectangular boxes or lines, the border symbol type, 1 through 4.
  555.         For individual box-drawing characters, the decimal ASCII code.
  556.  
  557. BgCol : Background color.
  558.  
  559. FgCol : Foreground color.
  560.  
  561. Code  : Identifies the item:
  562.          Boxes             = 1;
  563.          Labels            = 2;
  564.          Integer variables = 3;
  565.          Real variables    = 4;
  566.          String variables  = 5;
  567.          Date variables    = 6;
  568.  
  569. Protec/Ref: Boxes:
  570.                      Mother boxes = 0;
  571.                      Subcomponents <>0, point at the item number of the
  572.                      mother box.
  573.  
  574.             Labels:  Unused.
  575.  
  576.             Variables:
  577.                      Protected     = 1;
  578.                      Not protected = 0;
  579.  
  580. Name     :  Boxes    :  Unused.
  581.  
  582.             Labels   :  Contains the label.
  583.  
  584.             Variables:  Name of the variable,  as input by the screen designer
  585.                         or as generated by ScreenEngine.
  586.  
  587. If the item is a variable, (Codes 3 through 6),  it will be followed by one or
  588. two more lines containing the minimum and maximum value for that variable.
  589.  
  590. The last line is always a *).
  591.  
  592.  
  593.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  594.  
  595.  
  596.  
  597.  
  598.  
  599.  
  600. Introduction                                                         Page    8
  601.  
  602.  
  603. ScreenEngine expects to  read an unmodified data file.  Therefore, very little
  604. validation  of the data is  made.  By changing the items  in the file with the
  605. help of an editor, you may cause ScreenEngine to crash.
  606.  
  607.  
  608. The Sample Files:
  609.  
  610. In your diskette you will find the following files:
  611.  
  612. SE.COM         :     The main program.
  613.  
  614. SE.000         :     The overlay file.   This file is used just to initialize
  615.                       the  program.  Once the Screen Design Menu is displayed,
  616.                       it is safe to remove the ScreenEngine disk.
  617.  
  618. SE.MSG         :     This file contains the messages that are displayed
  619.                       during the program's execution.
  620.  
  621. SE.MNU         :     This file contains the menus. Should not be changed.
  622.  
  623. SAMPLE.PAS     :     This file shows a typical, unedited program created with
  624.                       SE.
  625.  
  626. SAMPLE.COM      :    This  is a compiled version of the above.   You may input
  627.                       some  values  and find  out  how a  ScreenEngine created
  628.                       program will look and validate data.
  629.  
  630. ORBIT.PAS       :     This is a program with an opening screen designed with
  631.                       ScreenEngine,  and subsequently edited to take advantage
  632.                       of the array structure of the data.  If you have a color
  633.                       graphics adapter or compatible,  you will be able to run
  634.                       its compiled version.
  635.  
  636. ORBIT.COM       :     This is the compiled version of the above.
  637.  
  638. ORBIT.DOC       :     A very brief documentation of the program. Try it!
  639.  
  640.  
  641.  
  642.  
  643.  
  644.  
  645.  
  646.  
  647.  
  648.  
  649.  
  650.  
  651.  
  652.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  653.  
  654.  
  655.  
  656.  
  657.  
  658.  
  659. Main Menu                                                            Page    9
  660.  
  661.  
  662.                             ScreenEngine REFERENCE
  663.  
  664.  
  665.  
  666. 1.  The Main Menu.
  667.  
  668.     The  main  menu includes  the basic  processing options  for ScreenEngine.
  669.     These  allow the user to create new screens,  edit existing screens,  save
  670.     the current work,  clear the current screen and start a new one,  and quit
  671.     ScreenEngine.
  672.  
  673.  
  674. 1.1 MAKE
  675.  
  676. ==============================================================================
  677. Main Menu
  678. MAKE  Retrieve  Save  Clear  Quit
  679. Create a new screen or continue editing current one.
  680. ==============================================================================
  681.  
  682.       You  will choose the MAKE  option to begin designing  a new screen or if
  683.       you  have been editing an existing screen  and wish to re-edit some item
  684.       before  saving or quitting  ScreenEngine.  You will be  asked to enter a
  685.       valid  DOS file name.  This name will be used to create a disk file that
  686.       will contain the generated Turbo Pascal source code.  The same file name
  687.       will  be used  in association with  other prefixes to  name the internal
  688.       procedures to input,  outupt and edit data that will identify the screen
  689.       within  your program.   Use 8 characters  or less.  Use  only letters or
  690.       numbers following a letter,  with no blanks or other special characters.
  691.       Examples of valid identifiers are:
  692.  
  693.       Invntory
  694.       Address
  695.       DataBase
  696.       VisRecrd
  697.  
  698.       Examples of invalid identifiers are:
  699.  
  700.       123                (Does not start with a letter)
  701.       ClientInformation  (Too long)
  702.       Screen 1           (Imbedded blank)
  703.  
  704.       Then,  if you chose the name "VisRecrd",  for example, ScreenEngine will
  705.       create  several  procedures with  names like  InpVisRecrd,  OutVisRecrd,
  706.       EditVisRecrd within your generated code. (See Section 3.1).
  707.  
  708.  
  709.  
  710.  
  711.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  712.  
  713.  
  714.  
  715.  
  716.  
  717.  
  718. Main Menu                                                            Page   10
  719.  
  720.  
  721.  
  722. 1.2 Retrieve
  723.  
  724. ==============================================================================
  725. MAIN MENU
  726. Make  RETRIEVE  Save Clear Quit
  727. Retrieve a previously created screen to edit or combine with current one.
  728. ==============================================================================
  729.  
  730.       You  must  have a  previously saved  screen  in order  to use  this menu
  731.       selection. When you use RETRIEVE, ScreenEngine will ask you to enter the
  732.       filename in which your screen was saved, or type "?" to obtain a listing
  733.       of  the current  filenames in  your default  directory.  (See  "The File
  734.       Directory Utility" in the "Introduction to ScreenEngine".
  735.  
  736.  
  737.  
  738.       Combining previously created files.
  739.  
  740.       You may combine one or more stored screens with the one on which you are
  741.       currently  working.   By retrieving  each screen  in  turn you  may have
  742.       several  screens diplayed  on the monitor  at the  same time.  Remember,
  743.       however,   that if parts of  the screen to be  retrieved occupy the same
  744.       space  on the  monitor as that  which is currently  resident,  they will
  745.       cover (but not erase) the screen on which they are superimposed. You may
  746.       then  use  ScreenEngine editing  capabilities to  move items  around and
  747.       display all parts of the screen, or erase items not wanted.
  748.  
  749.  
  750. 1.3 Save.
  751.  
  752. ==============================================================================
  753. MAIN MENU
  754. Make  Retrieve  SAVE  Clear  Quit
  755. Save your work into a file.
  756. ==============================================================================
  757.  
  758.       If you wish to save your screen,  either as a final product or for later
  759.       editing,  use the SAVE option. The program will display the filename you
  760.       chose  under the  MAKE option  and ask  if you  want to  accept the name
  761.       and/or directory in which the file will be saved.  If you wish to change
  762.       either the filename or directory, you may do so at this point.
  763.  
  764.       ScreenEngine  will  then  save  your  file  in  the  directory  you have
  765.       selected.   If there is not enough room in that directory,  ScreenEngine
  766.       will  display the files and give you the  option to erase a file,  or to
  767.       change directory. You may also insert a new formatted floppy.
  768.  
  769.  
  770.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  771.  
  772.  
  773.  
  774.  
  775.  
  776.  
  777. Main Menu                                                            Page   11
  778.  
  779.  
  780.  
  781. 1.4 Clear.
  782.  
  783. ==============================================================================
  784. MAIN MENU
  785. Make  Retrieve  Save  CLEAR  Quit
  786. Clear current work and start a new screen.
  787. ==============================================================================
  788.  
  789.  
  790.       The  CLEAR option is used to clear the monitor area of all work to leave
  791.       it  ready for creating new screens or  editing old ones.  If you want to
  792.       save  the  work currently  on the  screen,  use  the SAVE  option before
  793.       CLEAR.  When you choose CLEAR the program will check to see if your work
  794.       has  been saved and will ask you in you  wish to save it if you have not
  795.       already done so.
  796.  
  797.  
  798. 1.5 Quit.
  799.  
  800. ==============================================================================
  801. MAIN MENU
  802. Make  Retrieve  Save  Clear  QUIT
  803. Quit ScreenEngine.
  804. ==============================================================================
  805.  
  806.        The  QUIT option  allows you to  leave ScreenEngine and  return to DOS.
  807.        The  program checks if you have save your work and will ask you to save
  808.        it  if you  have not  already done  so.  You  may want  to quit without
  809.        saving.
  810.  
  811.  
  812.  
  813.  
  814.  
  815.  
  816.  
  817.  
  818.  
  819.  
  820.  
  821.  
  822.  
  823.  
  824.  
  825.  
  826.  
  827.  
  828.  
  829.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  830.  
  831.  
  832.  
  833.  
  834.  
  835.  
  836. Screen Design Menu                                                   Page   12
  837. Creating Boxes
  838.  
  839.  
  840.  
  841. 2. Screen Design Menu
  842.  
  843.    The  screen design menu will appear if  your selection on the main menu was
  844.    either   Make  or Retrieve.  The Screen Design Menu is the vehicle by which
  845.    you will design your input/output screens. Each selection on this menu will
  846.    be  described and its sub-menu selections  examined in detail before moving
  847.    to  the next screen design  selection.  This menu is  always present on the
  848.    display. (See "Moving the Cursor Around the Screen").
  849.  
  850. 2.1 Box
  851.  
  852. ==============================================================================
  853. SCREEN DESIGN MENU
  854. BOX  Label  Variable  Change  Move  Duplicate  Alter  Erase Unerase Sort Quit
  855. Define a rectangular box, a line or any special graphic symbol.
  856. ==============================================================================
  857.  
  858.  
  859.     Boxes,  lines and graphic symbols are used to define and separate areas of
  860.     the  screen for organizational  purposes,  or to  emphasize certain areas.
  861.     These items are optional:  you may define input/output areas without using
  862.     any  boxes or lines.  However,  because of  the visual impact of a display
  863.     screen  well designed with boxes and separating lines of different colors,
  864.     it  is  highly  recommended  to add  those  eye-cathing  elements  to your
  865.     screens.   ScreenEngine  makes it  very easy  to  design and  layout these
  866.     elements to your screens.
  867.  
  868.     Within  ScreenEngine,  boxes may  be "Simple" or  "Complex".  A simple box
  869.     consist of just the outer frame.  Complex boxes contain internal divisions
  870.     made  up of lines,  other boxes  and box-drawing characters use to improve
  871.     the apperance of box and line intersections. Very intricate screen designs
  872.     may  be accomplished using the complex box  feature,  which is part of the
  873.     BOX submenu described below.
  874.  
  875.  
  876.     When  you select Box from the screen  Design Menu you must then choose the
  877.     type  of character to  be used for  drawing boxes or  lines;  you may also
  878.     choose  to create a "Complex" box.  The first four options above offer the
  879.     following charaters for drawing lines or boxes:
  880.  
  881.           1 =  use single line for box or line
  882.           2 =  use double line for box or line
  883.           3 =  use half-character wide solid line
  884.           4 =  use full-character wide solid line
  885.  
  886.  
  887.  
  888.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  889.  
  890.  
  891.  
  892.  
  893.  
  894.  
  895. Screen Design Menu                                                   Page   13
  896. Creating Boxes
  897.  
  898.  
  899.     If  you choose  to draw a  simple line  or box using  one of  the four box
  900.     drawing  characters,  select one number.   The following question will the
  901.     appear:
  902.  
  903.         Accept default colors for boxes and lines? Yes/No
  904.  
  905.     If you choose no,  you will be presented with 7 choices for the background
  906.     color  or shade inside  of the box,  and  15 choices for  the color of the
  907.     line  or  box  outline  itself.  After  making  these  choices  proceed as
  908.     follows.
  909.  
  910.     If you answer yes to the question above,  or if you are finished selecting
  911.     colors,  you will be asked to position the cursor on one corner of the box
  912.     or line,  and press [ENTER] to anchor the box or line corner to that point
  913.     on  the display.  You may expand or shrink  the box or line to any desired
  914.     size by using the cursor keys. (See Moving the Cursor Around the Screen").
  915.     With these keys you will control  a shaded area, depicting the boxed area,
  916.     to  appear and move on the screen.  The character used to show this box or
  917.     line  is not  the final  box-drawing character that  will be  used;  it is
  918.     simply a way of showing what area your line or box will cover.
  919.  
  920.     After you have expanded the box or line to the desired size, press [ENTER]
  921.     once  more to complete the figure on the screen.  ScreenEngine will return
  922.     to the Screen Design Menu.
  923.  
  924.     NOTE:   ScreenEngine uses only standard Turbo Pascal "write" procedures to
  925.     draw boxes.  Because of this, writing anything on row 25, column 80 of the
  926.     screen  will cause  the screen to  scroll up one  line.  ScreenEngine will
  927.     ignore  that corner when instructed  to design a box  that will go through
  928.     row 25, column 80.
  929.  
  930.  
  931.     2.1.2 Complex Box.
  932.  
  933.     Complex  boxes are  any boxes  in which a  simple four-sided  box has been
  934.     enhanced  by the  use of  special box-drawing  characters or  by "nesting"
  935.     other  boxes either inside or outside the main (or "Parent")  box.  TURBO-
  936.     SCREEN considers all components of a complex box as a unit, which makes it
  937.     easier to change, move or erase. Moreover,when designing boxes as complex,
  938.     ScreenEngine  needs only  one single procedure  call to  draw the complete
  939.     box,   thus saving  valuable code  space.  A  restriction of the  use of a
  940.     complex  box is that all  the components of the  complex box have the same
  941.     colors  for background  and for  foreground.  If you  need to  place a box
  942.     within  another  box of  a different  color,you must  use the  BOX command
  943.     already described.
  944.  
  945.  
  946.  
  947.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  948.  
  949.  
  950.  
  951.  
  952.  
  953.  
  954. Screen Design Menu                                                   Page   14
  955. Creating Labels
  956.  
  957.  
  958. 2.2 Label.
  959.  
  960. ==============================================================================
  961. SCREEN DESIGN MENU
  962. Box  LABEL  Variable  Change  Move  Duplicate  Alter  Erase Unerase Sort Quit
  963. Input a title.
  964. ==============================================================================
  965.  
  966.     In  ScreenEngine,  labels are  descriptors that tell  the screen user what
  967.     particular  item of information is required  or displayed at that point on
  968.     the  screen.  For instance,  if you want the user to enter somebody's last
  969.     name on the screen the label for this area might be:
  970.  
  971.          "Last Name:"
  972.  
  973.  
  974.     ScreenEngine  will then  ask you  to position the  cursor at  the point at
  975.     which  you  want  the label  to  appear  and enter  your  label.   Use the
  976.     backspace,   [Del],  [Ins]  and Right and  Left arrow keys  to correct any
  977.     mistakes  you may  make.  Notice that  if you erase  some characters,  the
  978.     background  area will  be larger  than the length  of the  label until you
  979.     re-type some characters over it, or press [Enter] to finish your label.
  980.  
  981.     After your label is complete, ScreenEngine will redisplay the Change Label
  982.     Menu,   which is explained in section 2.4.  If you do not want to make any
  983.     changes at this point, choose the "Execute" option to return to the screen
  984.     design menu.
  985.  
  986.  
  987.  
  988.  
  989.  
  990.  
  991.  
  992.  
  993.  
  994.  
  995.  
  996.  
  997.  
  998.  
  999.  
  1000.  
  1001.  
  1002.  
  1003.  
  1004.  
  1005.  
  1006.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  1007.  
  1008.  
  1009.  
  1010.  
  1011.  
  1012.  
  1013. Screen Design Menu                                                   Page   15
  1014. Creating Variables
  1015.  
  1016.  
  1017. 2.3 Variable.
  1018.  
  1019.  
  1020.     This  selection of the  Screen Design  Menu enables  you to  locate on the
  1021.     screen and to describe actual Pascal variables to be input or displayed on
  1022.     the screen.
  1023.  
  1024.     There are four types of variables in ScreenEngine:  Integer,  real, string
  1025.     and  date.  The first three types  correspond to the standard Turbo Pascal
  1026.     variables. The "date" is a type of string variables which contains 6 ASCII
  1027.     characters.   Internally these  characters are  organized as YYMMDD.  This
  1028.     allows for dates to be compared and sorted in an application program.
  1029.  
  1030.     ScreenEngine  has a  number of options  to display and/or  input date type
  1031.     variables, as will be shown below.
  1032.  
  1033.     When you choose the Variable selection,  ScreenEngine will ask you to move
  1034.     the  cursor to the screen  location at which you  want to display or input
  1035.     the variable. You indicate the location of the first character by pressing
  1036.     [Enter].  Then, you may press the [Space] bar to indicate the total length
  1037.     of  the field where your variable  will be displayed.  Press [Enter] again
  1038.     when  you are finished.  ScreenEngine  assumes several default values when
  1039.     you  first create a variable.  ScreenEngine will then display the Variable
  1040.     Change  Menu and a  small window will appear  informing you of the current
  1041.     features  of the  variable.  You may  want to change them  as explained in
  1042.     Section 2.4.3. Proceed with your changes and select "Execute" to return to
  1043.     the screen design menu.
  1044.  
  1045.  
  1046.  
  1047.  
  1048.  
  1049.  
  1050.  
  1051.  
  1052.  
  1053.  
  1054.  
  1055.  
  1056.  
  1057.  
  1058.  
  1059.  
  1060.  
  1061.  
  1062.  
  1063.  
  1064.  
  1065.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  1066.  
  1067.  
  1068.  
  1069.  
  1070.  
  1071.  
  1072. Screen Design Menu                                                   Page   16
  1073. Change
  1074.  
  1075.  
  1076. 2.4 Change.
  1077.  
  1078. ==============================================================================
  1079. SCREEN DESIGN MENU
  1080. Box  Label  Variable  CHANGE  Move  Duplicate  Alter  Erase Unerase Sort Quit
  1081. Modify  any single item on  the screen (Label,variable type,color,format,etc.)
  1082. ==============================================================================
  1083.  
  1084.  
  1085.     When  the "Change"  option is selected  from the Screen  Design Menu,  the
  1086.     following message is displayed:
  1087.  
  1088.              CHANGE. Position cursor on item to be changed and press [ENTER].
  1089.  
  1090.     Once  you have selected the item to be changed,  ScreenEngine will display
  1091.     one  of three menus according to whether the  item is a box,  a label or a
  1092.     variable.   Notice that the changes you make are not executed immediately,
  1093.     but  you  must choose  the  "Execute" option  of  each menu  to  make them
  1094.     effective.
  1095.  
  1096.  
  1097. 2.4.1 Changing Boxes.
  1098.  
  1099.       Selecting a  box,   a line  or a  graphic character  to be  changed will
  1100.       display the following menu:
  1101.  
  1102.       Change (Box)
  1103.                   Background:
  1104.  
  1105.  
  1106. ==============================================================================
  1107. CHANGE  BOX OR GRAPHICS CHAR.  Make all  your choices and type "E" to proceed:
  1108. BACKGROUND  Foreground  Type  Size  Execute
  1109. Change the color of the background
  1110. ==============================================================================
  1111.  
  1112.       This  option  will  allow  you  to specify  a  different  color  for the
  1113.       background.   If you  marked a  complex box,   all subcomponents  of the
  1114.       complex  box will automatically change background color. (See "Menus for
  1115.       Color or Monochrome monitors").  If the element at which you pointed was
  1116.       a  subcomponent of a complex box,  ScreenEngine will not allow change of
  1117.       background or border symbol colors.
  1118.  
  1119.  
  1120.  
  1121.  
  1122.  
  1123.  
  1124.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  1125.  
  1126.  
  1127.  
  1128.  
  1129.  
  1130.  
  1131. Screen Design Menu                                                   Page   17
  1132. Change
  1133.  
  1134.  
  1135.  
  1136.       Change (Box)
  1137.                    Foreground:
  1138.  
  1139. ==============================================================================
  1140. CHANGE  BOX OR GRAPHICS CHAR.  Make all  your choices and type "E" to proceed:
  1141. Background  FOREGROUND  Type  Size  Execute
  1142. Change the color of the box border symbol
  1143. ==============================================================================
  1144.  
  1145.       This  option will  allow you  to specify a  different color  for the box
  1146.       border.   If you marked a complex box,  all subcomponents of the complex
  1147.       box will automatically change box border color.  See "Menus for Color or
  1148.       Monochrome monitors".
  1149.  
  1150.  
  1151.       Change (Box)
  1152.                   Type:
  1153.  
  1154. ==============================================================================
  1155. CHANGE  BOX OR GRAPHICS CHAR.  Make all  your choices and type "E" to proceed:
  1156. Background  Foreground  TYPE  Size  Execute
  1157. Change the box border symbol
  1158. ==============================================================================
  1159.  
  1160.       This  option will display the menu shown below,  which is similar to the
  1161.       one  shown when designing a box.  The only difference between both menus
  1162.       is  that the "Change  (Box)  Type" menu does  not offer  a "complex box"
  1163.       option:
  1164.  
  1165.  
  1166. ==============================================================================
  1167. Select type of graphic character for Box or line, or make complex box.
  1168. 1=--------  2= =========  3=            4=
  1169. Use single line for box or line
  1170. ==============================================================================
  1171.  
  1172.  
  1173.        Change (Box)
  1174.                    Size:
  1175.  
  1176. ==============================================================================
  1177. CHANGE  BOX OR GRAPHICS CHAR.  Make all  your choices and type "E" to proceed:
  1178. Background  Foreground  Type  SIZE  Execute
  1179. Change the size of the box
  1180. ==============================================================================
  1181.  
  1182.  
  1183.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  1184.  
  1185.  
  1186.  
  1187.  
  1188.  
  1189.  
  1190. Screen Design Menu                                                   Page   18
  1191. Change
  1192.  
  1193.  
  1194.  
  1195.       This  option is not  offered for individual  symbols.  ScreenEngine will
  1196.       display  the current  box in highlighted  mode.  Use the  cursor keys to
  1197.       enlarge  or decrease the size  of the box.  If  you wanted to change the
  1198.       size to the left or up, you may have to move the box such that its upper
  1199.       left  corner occupies  the position  you want it  to,  and  next use the
  1200.       Change Size option to move the lower left corner to its new position.
  1201.  
  1202.  
  1203.       Change (Box)
  1204.                   Execute:
  1205.  
  1206. ==============================================================================
  1207. CHANGE BOX OR GRAPHICS CHAR. Make all your choices and type "E" to proceed:
  1208. Background  Foreground  Type  Size  EXECUTE
  1209. Proceed with the changes and return to screen design menu
  1210. ==============================================================================
  1211.  
  1212.       This  option makes effective all changes and return to the screen design
  1213.       menu
  1214.  
  1215.  
  1216.  
  1217.  
  1218. 2.4.2 Change Label.
  1219.  
  1220.       Change (Label)
  1221.                     Background
  1222.  
  1223.  
  1224. ==============================================================================
  1225. CHANGE LABEL. Make all your changes and type "E" to proceed
  1226. BACKGROUND  Foreground  Label  Execute
  1227. Change the color of the label background
  1228. ==============================================================================
  1229.  
  1230.       This  choice allows you to  modify the background color  of the label at
  1231.       which you pointed.
  1232.  
  1233.  
  1234.  
  1235.  
  1236.  
  1237.  
  1238.  
  1239.  
  1240.  
  1241.  
  1242.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  1243.  
  1244.  
  1245.  
  1246.  
  1247.  
  1248.  
  1249. Screen Design Menu                                                   Page   19
  1250. Change
  1251.  
  1252.  
  1253.       Change (Label)
  1254.                     Foreground:
  1255.  
  1256.  
  1257. ==============================================================================
  1258. CHANGE LABEL. Make all your changes and type "E" to proceed
  1259. Background  FOREGROUND  Label  Execute
  1260. Change the color of the label text
  1261. ==============================================================================
  1262.  
  1263.       This  choice  allows  you  to  change  the  color  of  the  alphanumeric
  1264.       characters that form the label.
  1265.  
  1266.  
  1267.       Change (Label)
  1268.                     Label:
  1269.  
  1270. ==============================================================================
  1271. CHANGE LABEL. Make all your changes and type "E" to proceed
  1272. Background  Foreground  LABEL  Execute
  1273. Change the text or length of the label
  1274. ==============================================================================
  1275.  
  1276.       Change  label allows you to modify the label itself,  adding or deleting
  1277.       characters.  Use the cursor keys,  the backspace, delete and Insert keys
  1278.       to assist you.
  1279.  
  1280.  
  1281.       Return to screen design menu:
  1282.  
  1283. ==============================================================================
  1284. CHANGE LABEL. Make all your changes and type "E" to proceed
  1285. Background  Foreground  Label  EXECUTE
  1286. Proceed with the changes and return to screen design menu
  1287. ==============================================================================
  1288.  
  1289.  
  1290. 2.4.3 Change Variable.
  1291.  
  1292.       When  you select  a variable to  be changed,   ScreenEngine displays the
  1293.       Change Variable menu.  In addition,  a small window opens displaying the
  1294.       current name, type, display format if any, protection attribute, and, if
  1295.       the  variable is not protected,  the minimum and maximum values for data
  1296.       validation.   Data in this window  will change instantaneously after you
  1297.       make any modification:
  1298.  
  1299.  
  1300.  
  1301.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  1302.  
  1303.  
  1304.  
  1305.  
  1306.  
  1307.  
  1308. Screen Design Menu                                                   Page   20
  1309. Change
  1310.  
  1311.  
  1312.  
  1313.                    +-----------------------------+
  1314.                    | Name:                       |
  1315.                    | Type:                       |
  1316.                    | Display format:             |
  1317.                    | Protection                  |
  1318.                    |                             |
  1319.                    | Maximum Value:              |
  1320.                    |                             |
  1321.                    | Minimum Value:              |
  1322.                    |                             |
  1323.                    +-----------------------------+
  1324.  
  1325.  
  1326.       Change (Variable)
  1327.                        Background:
  1328.  
  1329. ==============================================================================
  1330. CHANGE VARIABLE. Make all your changes and type "E" to proceed
  1331. BACKGROUND  Foreground Name  Type  Length  Display  Protection  MinMax Execute
  1332. Change the background color of the variable input/output field.
  1333. ==============================================================================
  1334.  
  1335.       This option lets you specify a new background color.
  1336.  
  1337.  
  1338.       Change (Variable)
  1339.                        Foreground:
  1340.  
  1341. ==============================================================================
  1342. CHANGE VARIABLE. Make all your changes and type "E" to proceed
  1343. Background  FOREGROUND Name  Type  Length  Display  Protection  MinMax Execute
  1344. Change the colors of the numbers or characters.
  1345. ==============================================================================
  1346.       This  option lets you specify a new  color of the characters to be input
  1347.       or displayed at this location.
  1348.  
  1349.  
  1350.       Change (Variable)
  1351.                        Name:
  1352.  
  1353. ==============================================================================
  1354. CHANGE VARIABLE. Make all your changes and type "E" to proceed
  1355. Background  Foreground NAME  Type  Length  Display  Protection  MinMax Execute
  1356. Change the name of the variable.
  1357. ==============================================================================
  1358.  
  1359.  
  1360.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  1361.  
  1362.  
  1363.  
  1364.  
  1365.  
  1366.  
  1367. Screen Design Menu                                                   Page   21
  1368. Change
  1369.  
  1370.  
  1371.       If  you are using  ScreenEngine only to  design a screen  and obtain the
  1372.       coordinates of the display fields, you do not need to give a name to the
  1373.       variables.   However,  if you wish to generate the complete Turbo-Pascal
  1374.       source code,it is convenient to give the variable a name. If you do not,
  1375.       ScreenEngine will generate a name automatically.
  1376.  
  1377.  
  1378.       Change (Variable)
  1379.                        Type
  1380.  
  1381. ==============================================================================
  1382. CHANGE VARIABLE. Make all your changes and type "E" to proceed
  1383. Background  Foreground Name  TYPE  Length  Display  Protection  MinMax Execute
  1384. Change from integer to real, string, or date, real to integer or string, etc.
  1385. ==============================================================================
  1386.  
  1387.  
  1388.       Selecting  CHANGE  TYPE  will  cause  ScreenEngine  to  go  through  the
  1389.       following steps:
  1390.  
  1391.  
  1392.         1) Display the Variable Type Menu.
  1393.  
  1394.         2) Prompt the user to input the display format of the variable for
  1395.            real or date-type variables.
  1396.  
  1397.  
  1398.       Change (Variable)
  1399.                         Type
  1400.                              Integer:
  1401.  
  1402. ==============================================================================
  1403. Select type of variable
  1404. INTEGER  Real  String  Date
  1405. Variable will be a Turbo Pascal integer.
  1406. ==============================================================================
  1407.  
  1408.        Integer  variables  follow  the  definition  for  Turbo  Pascal integer
  1409.        variables.   There is  only one  display format  for integer variables.
  1410.        Therefore, the user will not be asked to choose a format.
  1411.  
  1412.  
  1413.  
  1414.  
  1415.  
  1416.  
  1417.  
  1418.  
  1419.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  1420.  
  1421.  
  1422.  
  1423.  
  1424.  
  1425.  
  1426. Screen Design Menu                                                   Page   22
  1427. Change
  1428.  
  1429.  
  1430.  
  1431.        Change (Variable)
  1432.                         Type
  1433.                             Real:
  1434.  
  1435. ==============================================================================
  1436. Select type of variable
  1437. Integer  REAL  String  Date
  1438. Variable will be a Turbo Pascal real.
  1439. ==============================================================================
  1440.  
  1441.  
  1442.       Real  variables correspond  to Turbo  Pascal real  variables.  The first
  1443.       option  ScreenEngine will give you after selecting Real is the selection
  1444.       of the  output format of this variable.   This option is explained below
  1445.       under the "Change (Variable) Display".
  1446.  
  1447.  
  1448.       Change (Variable)
  1449.                        Type
  1450.                             String:
  1451.  
  1452. ==============================================================================
  1453. Select type of variable
  1454. Integer  Real  STRING  Date
  1455. Variable will be a String of up to 80 characters.
  1456. ==============================================================================
  1457.  
  1458.       String  variables  correspond  to Turbo  Pascal  String  type variables.
  1459.       ScreenEngine  will declare these variables as String[nn] where nn is the
  1460.       length  of the field in which the  variables will be displayed or input.
  1461.       String  variables have  no format.   ScreenEngine allows  you to specify
  1462.       maximum or minimum values to validate these variables.
  1463.  
  1464.       Change (Variable)
  1465.                        Type
  1466.                            Date:
  1467.  
  1468. ==============================================================================
  1469. Select type of variable
  1470. Integer  Real  String  DATE
  1471. Variable will be a String[6] containing a date.
  1472. ==============================================================================
  1473.  
  1474.       Date  variables were described in Section 2.3.  ScreenEngine will prompt
  1475.  
  1476.  
  1477.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  1478.  
  1479.  
  1480.  
  1481.  
  1482.  
  1483.  
  1484. Screen Design Menu                                                   Page   23
  1485. Change
  1486.  
  1487.  
  1488.       the user to choose a format for these variables.  See "Change (Variable)
  1489.       Display",   below,  for the different  display options available to Date
  1490.       variables.
  1491.  
  1492.  
  1493.  
  1494.  
  1495.  
  1496.  
  1497.  
  1498.  
  1499.  
  1500.  
  1501.  
  1502.  
  1503.  
  1504.  
  1505.  
  1506.  
  1507.  
  1508.  
  1509.  
  1510.  
  1511.  
  1512.  
  1513.  
  1514.  
  1515.  
  1516.  
  1517.  
  1518.  
  1519.  
  1520.  
  1521.  
  1522.  
  1523.  
  1524.  
  1525.  
  1526.  
  1527.  
  1528.  
  1529.  
  1530.  
  1531.  
  1532.  
  1533.  
  1534.  
  1535.  
  1536.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  1537.  
  1538.  
  1539.  
  1540.  
  1541.  
  1542.  
  1543. Screen Design Menu                                                   Page   24
  1544. Change
  1545.  
  1546.  
  1547.  
  1548.       Change (Variable)
  1549.                         Length:
  1550.  
  1551. ==============================================================================
  1552. CHANGE VARIABLE. Make all your changes and type "E" to proceed
  1553. Background  Foreground Name  Type  LENGTH  Display  Protection  MinMax Execute
  1554. Change the length of the display field.
  1555. ==============================================================================
  1556.  
  1557.       You  may be able to change the  length of the input/output field for any
  1558.       variables except Date,  because these have a fixed 8 position field. For
  1559.       the other variable types,  ScreenEngine will clear the small window from
  1560.       the  display to allow you to view the area in which the variable will be
  1561.       located,   and ask you to  press the [Space] bar  to input the new field
  1562.       length.   Press [Enter when finished.  If you do not input enough spaces
  1563.       for variables with scientific format display, ScreenEngine will beep and
  1564.       an  error message will be displayed.   Correct the length of the display
  1565.       field and press [Enter] to return to the Change variable menu.
  1566.  
  1567.  
  1568. ==============================================================================
  1569. CHANGE VARIABLE. Make all your changes and type "E" to proceed
  1570. Background  Foreground Name  Type  Length  DISPLAY  Protection  MinMax Execute
  1571. Change the display format of integer, real or date variables.
  1572. ==============================================================================
  1573.  
  1574.  
  1575.       Change (Variable)
  1576.                        Display:
  1577.  
  1578.       ScreenEngine  allows you to  specify four different  display formats for
  1579.       real and six different display formats for date variables.  According to
  1580.       the  type of  variable you  are changing,   ScreenEngine will  display a
  1581.       different menu.
  1582.  
  1583.       Change (Real variable)
  1584.                             Display
  1585.                                    Scientific:
  1586.  
  1587. ==============================================================================
  1588. Select output format
  1589. SCIENTIFIC  Fixed  Dollar  Percent  Comma
  1590. Display variable with a Scientific format such as 1.234E-5
  1591. ==============================================================================
  1592.  
  1593.  
  1594.  
  1595.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  1596.  
  1597.  
  1598.  
  1599.  
  1600.  
  1601.  
  1602. Screen Design Menu                                                   Page   25
  1603. Change
  1604.  
  1605.  
  1606.       If you select SCIENTIFIC format output the variable will be displayed in
  1607.       scientific format,  but the user may enter the variable in fixed format.
  1608.       When  selecting Scientific format,  ScreenEngine  will check if there is
  1609.       enough space in the display field to accomodate the exponent, the signs,
  1610.       the  letter E,  and  the decimal point.   If there is  not enough space,
  1611.       ScreenEngine  will  beep  and display  an  error message  asking  you to
  1612.       increase the length of the display field.  Proceed with the corrections,
  1613.       press [Enter] and return to the Change Variable menu.
  1614.  
  1615.  
  1616.       Change (Real variable)
  1617.                             Display
  1618.                                     Fixed:
  1619.  
  1620. ==============================================================================
  1621. Select output format
  1622. Scientific  FIXED  Dollar  Percent  Comma
  1623. Display variable with a Fixed format such as 1234.56
  1624. ==============================================================================
  1625.  
  1626.       After  you select Fixed format,  ScreenEngine  will ask you to input the
  1627.       number of decimals in the field.
  1628.  
  1629.  
  1630.       Change (Real variable)
  1631.                             Display
  1632.                                     Dollar:
  1633.  
  1634. ==============================================================================
  1635. Select output format
  1636. Scientific  Fixed  DOLLAR  Percent  Comma
  1637. Display variable with a Dollar sign format such as $1,234.56
  1638. ==============================================================================
  1639.  
  1640.       Variables displayed with a Dollar sign format will have a leading $; the
  1641.       thousands,  millions,  etc. will be separated by commas. Negative values
  1642.       will be enclosed in parenthesis, as ($33,251.25).
  1643.  
  1644.       In input,  commas typed by the user will be ignored. Negative values may
  1645.       be input either with a minus sign or a leading opening parenthesis.
  1646.  
  1647.       ScreenEngine  will ask you to input the number of decimals in the field.
  1648.       Choose the default of 2 by pressing [ENTER],  or input any other allowed
  1649.       number.
  1650.  
  1651.  
  1652.  
  1653.  
  1654.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  1655.  
  1656.  
  1657.  
  1658.  
  1659.  
  1660.  
  1661. Screen Design Menu                                                   Page   26
  1662. Change
  1663.  
  1664.  
  1665.  
  1666.       Change (Real variable)
  1667.                             Display
  1668.                                    Percent:
  1669.  
  1670. ==============================================================================
  1671. Select output format
  1672. Scientific  Fixed  Dollar  PERCENT  Comma
  1673. Display variable with a Percent sign format such as 12.43%
  1674. ==============================================================================
  1675.  
  1676.       Variables with a percent format will be multiplied by 100.0 before being
  1677.       displayed;   a % sign will be added at the end;  a comma will be used to
  1678.       separate every 3 digits over 1,000%;  negative numbers will be displayed
  1679.       with a leading minus sign.
  1680.  
  1681.       In  input,  the commas  will be ignored,   and the percent  sign will be
  1682.       properly   considered.   That  is,   if  the  user  inputs  1.23%,   the
  1683.       corresponding  variable will take the value  0.0123.  If the user inputs
  1684.       1.23, the variable will take the value 1.23, which corresponds to 123.0%
  1685.  
  1686.  
  1687.       Change (Real variable)
  1688.                             Display
  1689.                                    Comma:
  1690.  
  1691. ==============================================================================
  1692. Select output format
  1693. Scientific  Fixed  Dollar  Percent  COMMA
  1694. Display variable with a comma format such as 1,234.56
  1695. ==============================================================================
  1696.       The  comma display format  works identically to  the dollar sign format,
  1697.       except that there is no leading $ in the field.
  1698.  
  1699.       In input,  commas typed by the user will be ignored. Negative values may
  1700.       be input either with a minus sign or a leading opening parenthesis.
  1701.  
  1702.  
  1703.       Change (Variable)
  1704.                        Protection:
  1705.  
  1706. ==============================================================================
  1707. CHANGE VARIABLE. Make all your changes and type "E" to proceed
  1708. Background  Foreground Name  Type  Length  Display  PROTECTION  MinMax Execute
  1709. Change this variable from display-only to display and change, or viceversa.
  1710. ==============================================================================
  1711.  
  1712.  
  1713.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  1714.  
  1715.  
  1716.  
  1717.  
  1718.  
  1719.  
  1720. Screen Design Menu                                                   Page   27
  1721. Change
  1722.  
  1723.  
  1724.        In ScreenEngine  "Protection" of  a variable  refers to  as whether the
  1725.        user of the generated program will be allowed to change the variable or
  1726.        not.   After selecting  "Protection",  ScreenEngine will  display a sub
  1727.        menu, the options of which are described next.
  1728.  
  1729. ==============================================================================
  1730. Should this variable be protected from being changed by the user?
  1731. YES  No
  1732. The generated program will only display this variable.
  1733. ==============================================================================
  1734.  
  1735.  
  1736. ==============================================================================
  1737. Should this variable be protected from being changed by the user?
  1738. Yes  NO
  1739. The user will be allowed to input and/or edit this variable.
  1740. ==============================================================================
  1741.  
  1742.  
  1743.        Selecting "No" from the above menu will direct ScreenEngine to generate
  1744.        code  that will  prompt the  user to input  a value  for this variable.
  1745.        Selecting  "Yes",   will cause  your generated  program to  display the
  1746.        variable without ever prompting the user to input or modify this field.
  1747.        You  may  want to  use this  feature  on some  ocasions,  such  as when
  1748.        displaying  today's date,  or other information the user is not allowed
  1749.        to modify.
  1750.  
  1751.  
  1752.        Change (Variable)
  1753.                         MinMax:
  1754.  
  1755. ==============================================================================
  1756. CHANGE VARIABLE. Make all your changes and type "E" to proceed
  1757. Background  Foreground Name  Type  Length  Display  Protection  MINMAX Execute
  1758. Change the minimum or maximum values the user can specify for this variable.
  1759. ==============================================================================
  1760.  
  1761.        The  Minmax option allows you to specify the maximum and minimum values
  1762.        that  a  user can  input  for a  variable.   ScreenEngine will  ask the
  1763.        following question:
  1764.  
  1765.  
  1766. ==============================================================================
  1767. VARIABLE RANGE: Do you want to specify a range of acceptable values?
  1768. NO  Yes
  1769. Accept any value.
  1770. ==============================================================================
  1771.  
  1772.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  1773.  
  1774.  
  1775.  
  1776.  
  1777.  
  1778.  
  1779. Screen Design Menu                                                   Page   28
  1780. Change
  1781.  
  1782.  
  1783.  
  1784.  
  1785.       Select  this option if your program does  not need to check for validity
  1786.       of data.
  1787.  
  1788.       If  your  program requires  a check  for validity  of data,   select the
  1789.       following option:
  1790.  
  1791. ==============================================================================
  1792. VARIABLE RANGE: Do you want to specify a range of acceptable values?
  1793. No  YES
  1794. Input a minimum and maximum value within which the data will be valid.
  1795. ==============================================================================
  1796.  
  1797.  
  1798.  
  1799.       ScreenEngine  then will ask  you for the minimum  and maximum values for
  1800.       this variable.  The generated code will check for data validity when the
  1801.       user inputs new data, or modifies existing information.
  1802.  
  1803.  
  1804.       Change (Variable)
  1805.                        Execute:
  1806.  
  1807. ==============================================================================
  1808. CHANGE VARIABLE. Make all your changes and type "E" to proceed
  1809. Background Foreground Name  Type  Length  Display  Protection  MinMax EXECUTE
  1810. Proceed with the changes and return to screen design menu.
  1811. ==============================================================================
  1812.  
  1813.        Choose  this option once you have  made all your changes.  ScreenEngine
  1814.        will make the changes effective and return to the Screen Design Menu.
  1815.  
  1816.  
  1817.  
  1818.  
  1819.  
  1820.  
  1821.  
  1822.  
  1823.  
  1824.  
  1825.  
  1826.  
  1827.  
  1828.  
  1829.  
  1830.  
  1831.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  1832.  
  1833.  
  1834.  
  1835.  
  1836.  
  1837.  
  1838. Screen Design Menu                                                   Page   29
  1839. Move
  1840.  
  1841.  
  1842. 2.5 Move
  1843.  
  1844. ==============================================================================
  1845. SCREEN DESIGN MENU
  1846. Box  Label  Variable  Change  MOVE  Duplicate  Alter  Erase Unerase Sort Quit
  1847. Move elsewhere any single item or several items in a rectangular screen range.
  1848. ==============================================================================
  1849.  
  1850.     The  Move option allows you to move any item elsewhere on the screen.  You
  1851.     may  also  want  to move  any  number  of items  fully  enclosed  within a
  1852.     rectangular area of the screen,  which is referred to as a "range".  After
  1853.     selecting "Move",  ScreenEngine will ask you to whether you want to move a
  1854.     single item or all items within a range.
  1855.  
  1856.  
  1857. ==============================================================================
  1858. WHAT DO YOU WANT TO MOVE?
  1859. ITEM  Range
  1860. Move a single item: Label, Variable, Line, Box, Complex box, box drawing char.
  1861. ==============================================================================
  1862.  
  1863.     If you choose this option, you will be asked to position the cursor on top
  1864.     of  the item you want to move.  Move  the cursor using the cursor keys and
  1865.     press [Enter] when it is positioned anywhere on the item.
  1866.  
  1867.  
  1868.  
  1869. ==============================================================================
  1870. WHAT DO YOU WANT TO MOVE?
  1871. Item  RANGE
  1872. Move elsewhere all items fully contained within a rectangular area.
  1873. ==============================================================================
  1874.  
  1875.     This  option lets you move all  items FULLY contained within a rectangular
  1876.     area  of  the screen.   Because of  the  special way  ScreenEngine handles
  1877.     complex boxes,  there is no need to use "Move range" to move a box and all
  1878.     its subcomponents.  After you select "Range", ScreenEngine will ask you to
  1879.     mark  the rectangular area of  the screen from where  you want to move the
  1880.     items.  After you select the rectangular area, use the cursor keys to show
  1881.     the  new  place  where  you  want the  items  to  be  moved.   Notice that
  1882.     ScreenEngine  will move a rectangular area of the same size as the one you
  1883.     indicated  to help you in determining the best new location.  The items to
  1884.     be moved are temporarily surrounded by a blinking box.
  1885.  
  1886.     WARNING:   Currently,  there is no provision  to prevent you from wrapping
  1887.     the  moving box around the screen.  If  you move the box beyond the screen
  1888.  
  1889.  
  1890.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  1891.  
  1892.  
  1893.  
  1894.  
  1895.  
  1896.  
  1897. Screen Design Menu                                                   Page   30
  1898. Move
  1899.  
  1900.  
  1901.     limits,   the box  will appear  distorted and  ScreenEngine will  not move
  1902.     anything.
  1903.  
  1904.  
  1905.  
  1906.  
  1907.  
  1908.  
  1909.  
  1910.  
  1911.  
  1912.  
  1913.  
  1914.  
  1915.  
  1916.  
  1917.  
  1918.  
  1919.  
  1920.  
  1921.  
  1922.  
  1923.  
  1924.  
  1925.  
  1926.  
  1927.  
  1928.  
  1929.  
  1930.  
  1931.  
  1932.  
  1933.  
  1934.  
  1935.  
  1936.  
  1937.  
  1938.  
  1939.  
  1940.  
  1941.  
  1942.  
  1943.  
  1944.  
  1945.  
  1946.  
  1947.  
  1948.  
  1949.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  1950.  
  1951.  
  1952.  
  1953.  
  1954.  
  1955.  
  1956. Screen Design Menu                                                   Page   31
  1957. Duplicate
  1958.  
  1959.  
  1960. 2.5 Duplicate
  1961.  
  1962. ==============================================================================
  1963. SCREEN DESIGN MENU
  1964. Box  Label  Variable  Change  Move  DUPLICATE  Alter  Erase Unerase Sort Quit
  1965. Copy any single item and its attributes anywhere on the screen.
  1966. ==============================================================================
  1967.  
  1968.  
  1969.     The  Duplicate option allows you to reproduce any item.  ScreenEngine will
  1970.     prompt you to 1)  mark the item you want to duplicate,  and 2) to mark the
  1971.     location  on the screen where  the new item will  be located.  Notice that
  1972.     complex boxes will be fully reproduced.  Notice also that when duplicating
  1973.     variables  the names of the variables will also be duplicated.  This would
  1974.     cause  the generated program  to give a compilation  time error.  To avoid
  1975.     this,  use the change command to change the name of the variables you have
  1976.     created by "Duplicating".
  1977.  
  1978.     ScreenEngine will check that the position on the screen you have indicated
  1979.     will not cause the item to wrap around the screen.
  1980.  
  1981.  
  1982.  
  1983.  
  1984.  
  1985.  
  1986.  
  1987.  
  1988.  
  1989.  
  1990.  
  1991.  
  1992.  
  1993.  
  1994.  
  1995.  
  1996.  
  1997.  
  1998.  
  1999.  
  2000.  
  2001.  
  2002.  
  2003.  
  2004.  
  2005.  
  2006.  
  2007.  
  2008.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  2009.  
  2010.  
  2011.  
  2012.  
  2013.  
  2014.  
  2015. Screen Design Menu                                                   Page   32
  2016. Alter
  2017.  
  2018.  
  2019. 2.6 Alter
  2020.  
  2021. ==============================================================================
  2022. SCREEN DESIGN MENU
  2023. Box  Label  Variable  Change  Move  Duplicate  ALTER  Erase Unerase Sort Quit
  2024. Alter default colors for screen, boxes, labels or variables.
  2025. ==============================================================================
  2026.     The  "Alter" option lets you change  the default background and foreground
  2027.     colors of the screen and any items to be designed.  It does not change the
  2028.     colors  of the items already placed on  the screen.  If you want to change
  2029.     the  background or foreground of the  items already on the screen,  please
  2030.     use  the "Change" option.   After you choose the  "Alter" option,  you are
  2031.     asked  to choose the type of item for  which you want to "Alter" the color
  2032.     defaults:
  2033.  
  2034. ==============================================================================
  2035. ALTER  DEFAULTS.   Make  all  your  changes  and  select  EXECUTE  to  proceed
  2036. SCREEN  Box  Label  Variable  Execute
  2037. Change screen color.
  2038. ==============================================================================
  2039.  
  2040.     Choosing  any of the options will  cause ScreenEngine to display the color
  2041.     menu for background and foreground. Since all are identical, they will not
  2042.     be  explained in further detail here.   After you have finished making the
  2043.     changes,  select "Execute" to make the changes effective and return to the
  2044.     screen design menu.
  2045.  
  2046.  
  2047.  
  2048.  
  2049.  
  2050.  
  2051.  
  2052.  
  2053.  
  2054.  
  2055.  
  2056.  
  2057.  
  2058.  
  2059.  
  2060.  
  2061.  
  2062.  
  2063.  
  2064.  
  2065.  
  2066.  
  2067.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  2068.  
  2069.  
  2070.  
  2071.  
  2072.  
  2073.  
  2074. Screen Design Menu                                                   Page   33
  2075. Erase
  2076.  
  2077.  
  2078. 2.6 Erase
  2079.  
  2080. ==============================================================================
  2081. SCREEN DESIGN MENU
  2082. Box  Label  Variable  Change  Move  Duplicate  Alter  ERASE Unerase Sort Quit
  2083. Erase any single item on the screen.
  2084. ==============================================================================
  2085.     The  "Erase" option lets you erase any items you have created.  If you are
  2086.     going to erase a complex box, all subcomponents of the box will be erased.
  2087.     ScreenEngine will ask you to indicate the item to be erased by placing the
  2088.     cursor over that item.
  2089.  
  2090.  
  2091.  
  2092.  
  2093.  
  2094.  
  2095.  
  2096.  
  2097.  
  2098.  
  2099.  
  2100.  
  2101.  
  2102.  
  2103.  
  2104.  
  2105.  
  2106.  
  2107.  
  2108.  
  2109.  
  2110.  
  2111.  
  2112.  
  2113.  
  2114.  
  2115.  
  2116.  
  2117.  
  2118.  
  2119.  
  2120.  
  2121.  
  2122.  
  2123.  
  2124.  
  2125.  
  2126.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  2127.  
  2128.  
  2129.  
  2130.  
  2131.  
  2132.  
  2133. Screen Design Menu                                                   Page   34
  2134. UnErase
  2135.  
  2136.  
  2137. 2.7 UnErase
  2138.  
  2139. ==============================================================================
  2140. SCREEN DESIGN MENU
  2141. Box  Label  Variable  Change  Move  Duplicate  Alter  Erase UNERASE Sort Quit
  2142. Erase any single item on the screen.
  2143. ==============================================================================
  2144.  
  2145.     The  "UnErase"  option lets  you recover  the  most recently  erased item.
  2146.     Because "Complex boxes" are actually composed of a number of items, TURBO-
  2147.     SCREEN will not be able to fully recover the complete Complex box. Unerase
  2148.     will recover just the "Mother" box.
  2149.  
  2150.  
  2151.  
  2152.  
  2153.  
  2154.  
  2155.  
  2156.  
  2157.  
  2158.  
  2159.  
  2160.  
  2161.  
  2162.  
  2163.  
  2164.  
  2165.  
  2166.  
  2167.  
  2168.  
  2169.  
  2170.  
  2171.  
  2172.  
  2173.  
  2174.  
  2175.  
  2176.  
  2177.  
  2178.  
  2179.  
  2180.  
  2181.  
  2182.  
  2183.  
  2184.  
  2185.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  2186.  
  2187.  
  2188.  
  2189.  
  2190.  
  2191.  
  2192. Screen Design Menu                                                   Page   35
  2193. Sort
  2194.  
  2195.  
  2196. 2.8 Sort
  2197.  
  2198. ==============================================================================
  2199. SCREEN DESIGN MENU
  2200. Box  Label  Variable  Change  Move  Duplicate  Alter  Erase Unerase SORT Quit
  2201. Variables  Boxes
  2202. ==============================================================================
  2203.  
  2204.     The "Sort" option has two different uses:
  2205.  
  2206.     1) Selecting the order in which the variables will be input in the
  2207.        generated program, and
  2208.  
  2209.     2) Selecting the order in which boxes are drawn on the screen.
  2210.  
  2211.     The  order in  which the  generated program will  ask the  variables to be
  2212.     input  depends  on  the  order  in which  the  variables  were  created in
  2213.     ScreenEngine. In many cases this will be a satisfactory order. However, if
  2214.     the  designer of the  screen moves some variables  around the screen,  the
  2215.     order  in which these variables will be  input may not be the most logical
  2216.     one.   In these cases,   the screen designer  may use "Sort"  to specify a
  2217.     particular order.
  2218.  
  2219.     The  second use of "Sort"  is helpful when the  screen designer decides to
  2220.     create  a new box that will surround one or more previously created boxes.
  2221.     Once  the new box is created,  it  will paint over the previous boxes.  In
  2222.     this  case,  the screen  designer can use  "Sort" to specify  the order in
  2223.     which  the boxes will be  drawn on the screen.   Because some of the boxes
  2224.     are  painted over,   ScreenEngine will show  the boxes  in a "see-through"
  2225.     mode, whereby the interior background of the box will not be painted.
  2226.  
  2227.     The procedure to use sort is identical in both cases:
  2228.  
  2229.     Place the cursor anywhere on the first variable or box, and press [Enter].
  2230.     ScreenEngine will write the sort order on the upper left corner of the box
  2231.     or  line,  or on the left corner of the variable input/output field.  Move
  2232.     the  cursor to the second  variable or box and  press [Enter].  Repeat the
  2233.     process  until you  reach the last  variable or box.   Press [Enter] twice
  2234.     while  on the last variable or box  (The first time to indicate the order,
  2235.     the  second time to  indicate that you  have finished).  ScreenEngine will
  2236.     internally sort the items and return to the Screen Design Menu.
  2237.  
  2238.  
  2239.  
  2240.  
  2241.  
  2242.  
  2243.  
  2244.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  2245.  
  2246.  
  2247.  
  2248.  
  2249.  
  2250.  
  2251. Screen Design Menu                                                   Page   36
  2252. Quit
  2253.  
  2254.  
  2255. 2.9 Quit
  2256.  
  2257. ==============================================================================
  2258. SCREEN DESIGN MENU
  2259. Box  Label  Variable  Change  Move  Duplicate  Alter  Erase Unerase Sort QUIT
  2260. Return to main menu to SAVE, RETRIEVE, CLEAR, or QUIT.
  2261. ==============================================================================
  2262.  
  2263.     The  "Quit" option lets you  return to the main menu.   You may be able to
  2264.     save  your work,  to combine the  current screen with a previously created
  2265.     one, to erase the screen or to leave ScreenEngine.
  2266.  
  2267.  
  2268.  
  2269.  
  2270.  
  2271.  
  2272.  
  2273.  
  2274.  
  2275.  
  2276.  
  2277.  
  2278.  
  2279.  
  2280.  
  2281.  
  2282.  
  2283.  
  2284.  
  2285.  
  2286.  
  2287.  
  2288.  
  2289.  
  2290.  
  2291.  
  2292.  
  2293.  
  2294.  
  2295.  
  2296.  
  2297.  
  2298.  
  2299.  
  2300.  
  2301.  
  2302.  
  2303.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  2304.  
  2305.  
  2306.  
  2307.  
  2308.  
  2309.  
  2310. Generated Program and Utilities                                      Page   37
  2311. Generated Program
  2312.  
  2313.  
  2314. 3.  The Generated Program and the ScreenEngine utilites.
  2315.  
  2316. 3.1 The Generated Program.
  2317.  
  2318. 3.1.1 Generated Procedures.
  2319.  
  2320.  
  2321.       ScreenEngine generates a Turbo Pascal program.  In the diskette you will
  2322.       find  a program  called "SAMPLE.PAS"  which is  a sample  of an unedited
  2323.       generated  program.   ScreenEngine creates  a  main program  and several
  2324.       procedures.   We  will describe  the generated  procedures with  base on
  2325.       SAMPLE.PAS.
  2326.  
  2327.       The following are the procedures you will find defined in SAMPLE.PAS:
  2328.  
  2329.       Program ScrnSample;
  2330.       procedure PutTitleScrnSample;
  2331.       procedure OutVarScrnSample(......
  2332.       procedure InpVarScrnSample(......
  2333.       procedure InpScrnSample(......
  2334.       procedure EditScrnSample(......
  2335.       procedure OutScrnSample(......
  2336.  
  2337.       ScreenEngine creates a small main program with the name ScrnXXXX,  where
  2338.       XXXX is the name you gave to the screen. The reason for creating a small
  2339.       main  program is that you  will immediately be able  to compile and test
  2340.       your  screen using your Turbo Pascal compiler.   Then you may be able to
  2341.       edit those parts of ScrnXXXX you are not interested in.
  2342.  
  2343.  
  2344.       PutTitleScrnXXXX.
  2345.  
  2346.       This procedure writes to the screen the labels and boxes you designed.
  2347.  
  2348.  
  2349.       OutVarScrnXXXX.
  2350.  
  2351.       This procedure writes the values of the variables.
  2352.  
  2353.  
  2354.       InpVarScrnXXXX.
  2355.  
  2356.       This procedure  INPuts  the  VARiables  from the  SCReen.   This  is the
  2357.       procedure  that moves the cursor from one variable input/display area to
  2358.       another. It works in the following fashion:
  2359.  
  2360.       1) The counter L is initialized at 1.
  2361.  
  2362.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  2363.  
  2364.  
  2365.  
  2366.  
  2367.  
  2368.  
  2369. Generated Program and Utilities                                      Page   38
  2370. Generated Program
  2371.  
  2372.  
  2373.  
  2374.       2) The "case"  statement  is used to go through all variables, according
  2375.          to the current value of L.
  2376.  
  2377.       3) At the end of the case statement, the program checks for the last key
  2378.          pressed when inputting any of the variables. The counter is increased
  2379.          by 1 if the last key pressed was the [Enter] (^M)  the [Tab] (^I), or
  2380.          the [Right] arrow key (Chr1 = #27 and Chr2 = 'P').
  2381.          The  counter is decreased by 1 if the  keys pressed were the [Up] key
  2382.          (Chr1  = #27 and Chr2 = 'H')  or the [Shift][Tab] key (Chr1 = #27 and
  2383.          Chr2 = #15).
  2384.  
  2385.       4) The process is repeated until the user presses the [Ctrl][Enter] keys
  2386.          (Chr1 = #10), or the [Enter] key was pressed after the final variable
  2387.          was  input.  In this case  the counter was set  to 1 which causes the
  2388.          termination of the "repeat" statement.
  2389.  
  2390.       The variables are requested in the order in which they were defined at
  2391. the
  2392.       moment  of designing  the screen,   or in the  order in  which they were
  2393.       "Sorted". If the variables appear in a column, using the [Up] and [Down]
  2394.       arrow  keys used to move  from item to item  is quite intuitive.  If the
  2395.       variables are in a row, the use of the [Up] and [Down] keys to move from
  2396.       one  variable to the one  on its left or the  one its right  is not very
  2397.       intuitive.   Notice that the  [Right] or [Left] arrow  keys are used for
  2398.       the  moving  the cursor  within  a variable's  input  field and  are not
  2399.       eligible  to be used to move from one field to another.  You may want to
  2400.       define some other keys by editing the generated source program.
  2401.  
  2402.  
  2403.       InpScrXXXX.
  2404.  
  2405.       This procedure has the following functions:
  2406.  
  2407.       1) Initialize variables. (You may want to do your own initialization).
  2408.       2) Put on the screen the values of the variables by calling
  2409. OutVarScrXXXX.
  2410.       3) Call the InpVarScrXXXX procedure to proceed to capture the values.
  2411.  
  2412.  
  2413.       EditScrXXXX.
  2414.  
  2415.       This  procedure differs from  InpScrXXXX in that  it does not initialize
  2416.       the variables.
  2417.  
  2418.  
  2419.       OutScrXXXX.
  2420.  
  2421.  
  2422.  
  2423.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  2424.  
  2425.  
  2426.  
  2427.  
  2428.  
  2429.  
  2430. Generated Program and Utilities                                      Page   39
  2431. Generated Program
  2432.  
  2433.  
  2434.       This  procedure simply displays  the screen with  labels,  boxes and the
  2435.       current  variable's  values,  without  allowing the  user to  change any
  2436.       variables.
  2437.  
  2438. 3.1.2 The Predefined Variables.
  2439.  
  2440.       ScreenEngine defines a few global variables for its own use:
  2441.  
  2442.       type
  2443.         TSStr     = String[80];
  2444.         TSCharSet = set of char;
  2445.         TSDate    = String[6];
  2446.  
  2447.       {Global variables}
  2448.       var
  2449.        TSString   :  TSStr;
  2450.        TSDefAttrib:  byte;    {Screen color attribute}
  2451.        TSInsMode  :  boolean; {keeps track of the insert key}
  2452.  
  2453.       Notice  that  all  those  variable type  and  variables  start  with the
  2454.       characters "TS", to avoid confusion with your program's own variables.
  2455.  
  2456.  
  2457.  
  2458.  
  2459.  
  2460.  
  2461.  
  2462.  
  2463.  
  2464.  
  2465.  
  2466.  
  2467.  
  2468.  
  2469.  
  2470.  
  2471.  
  2472.  
  2473.  
  2474.  
  2475.  
  2476.  
  2477.  
  2478.  
  2479.  
  2480.  
  2481.  
  2482.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  2483.  
  2484.  
  2485.  
  2486.  
  2487.  
  2488.  
  2489. Generated Program and Utilities                                      Page   40
  2490. The ScreenEngine Utilities
  2491.  
  2492.  
  2493.  
  2494. 3.2 The ScreenEngine Utilities.
  2495.  
  2496. 3.2.1 SE.UTL
  2497.  
  2498.     The file  SE.UTL contains the procedures and functions which are common to
  2499.     the remaining utilities.
  2500.     procedure Beep;
  2501.               Beeps the bell.
  2502.  
  2503.     procedure Box(UpperLeftX, UpperLeftY, LowerRightX, LowerRightY,
  2504.               BoxType, ColAttribute: byte;
  2505.               CharStr:TSStr);
  2506.  
  2507.               Draws a box on the screen with upper left corner at coordinates
  2508.               "UpperLeftX, UpperLeftY" and lower right corner at coordinates
  2509.               "Lower RightX and LowerRightY".
  2510.  
  2511.               Box type = 1 : single line.
  2512.                          2 : double line.
  2513.                          3 : half character wide line.
  2514.                          4 : full character wide line.
  2515.  
  2516.               ColAttribute : Color attribute.
  2517.  
  2518.               CharString : If not empty, this string contains the coordinates,
  2519.                            types of the boxes and ASCII codes of the box-
  2520.                            drawing symbols that form part of the "Mother box".
  2521.                            These values are codified into an ASCII string to
  2522.                            make a compact box drawing protocol.
  2523.  
  2524.     procedure GetString( xo,yo        : byte; ColAttribute : byte;
  2525.                      var StrVar       : TSStr;
  2526.                          Term1,
  2527.                          Term2        : TSCharSet;
  2528.                      var TC1,TC2      : Char;
  2529.                          L            : byte;
  2530.                          MinSt,
  2531.                          MaxSt        : TSStr);
  2532.  
  2533.     This procedure gets a string variable (StrVar)  at coordinates xo,  yo, in
  2534.     a  field of length "L" bytes.  The  maximum and minimum values allowed for
  2535.     this  string variable are MinSt and MaxSt,  respectively.  Term1 and Term2
  2536.     are two sets of characters that control when the procedure returns.  Term1
  2537.     normally   contains  the  [Enter]   (or  Return,   ^M),   [Control][Enter]
  2538.     (#10),  [Tab] (^I),  and Escape (#27)  characters. Term2 normally contains
  2539.     the  'P'  and  'H' characters  that  correspond to  the  second characters
  2540.  
  2541.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  2542.  
  2543.  
  2544.  
  2545.  
  2546.  
  2547.  
  2548. Generated Program and Utilities                                      Page   41
  2549. The ScreenEngine Utilities
  2550.  
  2551.  
  2552.     generated  by the [Down]  and [Up] arrow keys.   The last characters typed
  2553.     before the procedure returns are stored in TC1 and TC2.
  2554.  
  2555.  
  2556.     procedure GetVariable(x,y, ColAttribute : byte;
  2557.                      var S             : TSStr;
  2558.                           Term1,
  2559.                           Term2        : TSCharSet;
  2560.                       var TC1,TC2      : Char;
  2561.                           L            :byte);
  2562.  
  2563.     This  procedure reads a  string at coordinates  x,y.  The other parameters
  2564.     are  identical to those on GetString.  GetVariable is called by GetString,
  2565.     GetReal, GetInteger and GetDate.
  2566.  
  2567.  
  2568.     function MakeStr(C:Char;N:Integer): TSStr;
  2569.  
  2570.     This procedure makes a string of N identical characters(C);
  2571.  
  2572.  
  2573.     procedure NormCursor;
  2574.  
  2575.     This  procedure changes the  shape of the cursor  according to whether the
  2576.     [Ins] key has been pushed or not.
  2577.  
  2578.  
  2579.     procedurePeelBlanks(
  2580.                      var TSString:TSStr;
  2581.                      var NBlanks,L:byte);
  2582.  
  2583.     This  procedure  peels the  leading  blanks of  a  string and  returns the
  2584.     number of blanks peeled in NBlanks.
  2585.  
  2586.  
  2587.     procedure PutVariableOrLabel(xo,yo,ColAttribute:byte;
  2588.               TSString:TSStr;L:byte);
  2589.  
  2590.     Puts  the TSString variable on the  screen,  at xo,yo coordinates,  with a
  2591.     color defined by ColAttribute, on a field L bytes long.
  2592.  
  2593.  
  2594.     procedure scursor(dx:integer);
  2595.  
  2596.     Inline procedure called by NormCursor.
  2597.  
  2598.  
  2599.  
  2600.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  2601.  
  2602.  
  2603.  
  2604.  
  2605.  
  2606.  
  2607. Generated Program and Utilities                                      Page   42
  2608. The ScreenEngine Utilities
  2609.  
  2610.  
  2611.     procedure SetColor(ColAttribute:byte);
  2612.  
  2613.     Sets the foreground and background color.
  2614.  
  2615.  
  2616.     procedure ResetColor;
  2617.  
  2618.     Resets the color to the default screen colors.
  2619.  
  2620. 3.2.2 SEREAL.UTL
  2621.  
  2622.  
  2623.       procedure ConvReal(RealVar:real;L:byte;
  2624.                 Decimal,NumDec:integer;var TSString:TSStr);
  2625.  
  2626.       This procedure converts the real variable RealVar into a string
  2627.       TSString L bytes long, according to the folowing convention:
  2628.  
  2629.          Decimal = 0 for scientific format
  2630.          Decimal = 1 for fixed format
  2631.          Decimal = 2 for comma format
  2632.          Decimal = 3 for $ format
  2633.          Decimal = 4 for percent format
  2634.          NumDec  = number of decimals.
  2635.  
  2636.  
  2637.       procedure GetReal(
  2638.                            xo,yo        : byte;
  2639.                            ColAttribute : byte;
  2640.                        var RealVar      : real;
  2641.                     Term1, Term2        : TSCharSet;
  2642.                        var TC1,TC2      : Char;
  2643.                            L            : byte;
  2644.                            Decimal      : byte;
  2645.                            NumDec       : byte;
  2646.                            MinReal,
  2647.                            MaxReal      : real);
  2648.  
  2649.       procedure InsCommas(x:real;L,NDec:byte;var AVar:TSStr;DFormat:byte);
  2650.  
  2651.       procedure PeelChars(var TSString:TSStr;var factor:real);
  2652.  
  2653.  
  2654.  
  2655.  
  2656.  
  2657.  
  2658.  
  2659.  
  2660.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  2661.  
  2662.  
  2663.  
  2664.  
  2665.  
  2666.  
  2667. Generated Program and Utilities                                      Page   43
  2668. The ScreenEngine Utilities
  2669.  
  2670.  
  2671.       procedure PutReal(
  2672.                         xo,yo,ColAttribute:byte;
  2673.                         RealVar:real;
  2674.                         L:byte;
  2675.                         Decimal: integer;
  2676.                         NumDec : integer);
  2677.  
  2678.  
  2679. 3.2.2 SEINT.UTL
  2680.  
  2681.       procedure GetInteger(xo,yo        : byte;
  2682.                            ColAttribute : byte;
  2683.                        var IntVar       : integer;
  2684.                            Term1,
  2685.                            Term2        : TSCharSet;
  2686.                        var TC1,TC2      : Char;
  2687.                            L            : byte;
  2688.                            MinInt,
  2689.                            MaxInt       : integer);
  2690.  
  2691.       procedure PutInteger(xo,yo,ColorAttribute:byte;IntVar:integer;L:byte);
  2692.  
  2693. 3.2.3 SEDATE.UTL
  2694.  
  2695.       procedure GetDate(xo,yo            : byte;
  2696.                         ColAttribute     : byte;
  2697.                     var Date             : TSDate;
  2698.                         Term1,
  2699.                         Term2            : TSCharSet;
  2700.                     var Tc1,TC2          : Char;
  2701.                         Sep              : char;
  2702.                         Ypos,Mpos,Dpos   : byte;
  2703.                         MinDate,MaxDate  : TSDate);
  2704.  
  2705.       function MakeDateStr(Date:TSDate;Ypos,Mpos,Dpos:byte; Sep: char) :
  2706.       TSStr;
  2707.  
  2708.       This function converts a date from the internal 6 characters format into
  2709.       a string, according to the relative location of the month, year and day
  2710.       specified by the screen designer, and the character used to separate
  2711.       these items.
  2712.  
  2713.  
  2714.       procedure PutDate( xo,yo,
  2715.                         ColorAttribute: byte;
  2716.                         Date            : TSDate;
  2717.                         Sep             : char;
  2718.  
  2719.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  2720.  
  2721.  
  2722.  
  2723.  
  2724.  
  2725.  
  2726. Generated Program and Utilities                                      Page   44
  2727. The ScreenEngine Utilities
  2728.  
  2729.  
  2730.                         Ypos,Mpos,Dpos  : byte);
  2731.  
  2732.  
  2733.  
  2734.  
  2735.  
  2736.  
  2737.  
  2738.  
  2739.  
  2740.  
  2741.  
  2742.  
  2743.  
  2744.  
  2745.  
  2746.  
  2747.  
  2748.  
  2749.  
  2750.  
  2751.  
  2752.  
  2753.  
  2754.  
  2755.  
  2756.  
  2757.  
  2758.  
  2759.  
  2760.  
  2761.  
  2762.  
  2763.  
  2764.  
  2765.  
  2766.  
  2767.  
  2768.  
  2769.  
  2770.  
  2771.  
  2772.  
  2773.  
  2774.  
  2775.  
  2776.  
  2777.  
  2778.  
  2779.            Copyright Pedro J. Restrepo, (c) 1986. All Rights Reserved
  2780.  
  2781.  
  2782.  
  2783.